﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using System.Data.OleDb;

namespace popGis.LJP
{
    public partial class DataGridForm : Form
    {
        private DataTable thisDataTable;

        public DataGridForm(DataTable dTable)
        {
            InitializeComponent();
            thisDataTable = dTable;
        }

        private void DataGrid_Load(object sender, EventArgs e)
        {
            if (thisDataTable != null)
            {
                this.dataGridView1.DataSource = thisDataTable;
                this.Text = "表：[" + thisDataTable.TableName + "]"
                    + "  < 字段数：" + thisDataTable.Columns.Count.ToString()
                    + "   记录数：" + thisDataTable.Rows.Count.ToString() + " >";
            }
        }

    }
}
